Guide to Connectomes
Connectomes.Connectome — TypeConnectome(path::String; norm=true)Main type introduced by Connectomes.jl,
struct Connectome
parc::DataFrame
graph::SimpleWeightedGraph{Int64, Float64}
n_matrix::Matrix{Float64}
l_matrix::Matrix{Float64}
endwhere parc is the parcellation atlas, graph is a SimpleWeightedGraph encoding a weighted Connectome, n_matrix is the length matrix and l_matrix is the length matrix.
Example
julia> filter(Connectome(Connectomes.connectomepath()), 1e-2)
Parcellation:
83×8 DataFrame
Row │ ID Label Region Hemisphere x y z Lobe
│ Int64 String String String Float64 Float64 Float64 String
─────┼─────────────────────────────────────────────────────────────────────────────────────────────────────
1 │ 1 lateralorbitofrontal cortical right 25.0057 33.4625 -16.6508 frontal
2 │ 2 parsorbitalis cortical right 43.7891 41.4659 -11.8451 frontal
3 │ 3 frontalpole cortical right 9.59579 67.3442 -8.94211 frontal
4 │ 4 medialorbitofrontal cortical right 5.799 40.7383 -15.7166 frontal
5 │ 5 parstriangularis cortical right 48.3993 31.8555 5.60427 frontal
⋮ │ ⋮ ⋮ ⋮ ⋮ ⋮ ⋮ ⋮ ⋮
80 │ 80 Left-Accumbens-area subcortical left -8.14103 11.416 -6.32051 subcortex
81 │ 81 Left-Hippocampus subcortical left -25.5001 -22.6622 -13.6924 temporal
82 │ 82 Left-Amygdala subcortical left -22.7183 -5.11994 -18.8364 temporal
83 │ 83 brainstem subcortical none -6.07796 -31.5015 -32.8539 subcortex
74 rows omitted
Adjacency Matrix:
83×83 SparseArrays.SparseMatrixCSC{Float64, Int64} with 392 stored entries:
⣮⢛⣣⡠⠀⠀⠀⠀⠀⠀⠀⡁⠀⠀⠠⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠉⡺⢺⠒⣒⠄⢀⠀⠀⠀⠀⠄⠀⠀⠀⠀⠂⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠘⠜⠚⣠⣐⡐⠀⠀⣀⡄⠀⠀⠀⠀⠀⠈⠂⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠐⢐⠸⢴⡳⡄⠌⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠂⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⡀⠍⠯⡧⡄⠀⠀⠇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠄⠠⠀⠄⠀⠼⠁⠀⠀⠉⠯⡣⣄⠄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠄
⠀⠀⠀⠀⠀⠀⠀⠀⠤⠄⠀⠝⠏⠅⣀⣀⠀⠀⠀⠀⠀⠀⠀⠀⢀⠀⠀⠁
⠀⠂⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⡎⡭⡦⠂⠀⠀⠀⠀⠀⠀⠠⠀⠀⠀
⠀⠀⠈⠠⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠨⠋⡏⡩⡕⠀⠄⠀⠀⠐⠐⠀⠀⠀
⠀⠀⠀⠀⠈⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠑⠉⠡⡦⢥⠁⠀⢰⠶⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠈⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠁⠅⠓⢯⣳⣐⠂⠀⠀⢀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⠀⢀⣀⠰⠘⢺⣲⣀⠀⠘⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠐⠀⠂⠐⠀⠘⠃⠀⠀⠀⠘⢪⣲⣔⡂
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠄⠄⠀⠀⠀⠀⠀⠀⠀⠀⠐⠒⠀⠰⠹⠐⠀Plotting Example
Firstly, you will need to load Connectomes and a plotting backend from the Makie. Connectomes.jl uses the Makie.jl backend to organise and render plots.
There are several plotting methods available in Connectomes.jl. In keeping with the Julia custom, plotting methods ending with a ! add to an existing plot. Whereas those without ! create a Makie Scene.
using WGLMakie
using Connectomes
plot_cortex()